package com.accum.client;

import com.accum.client.presenter.Presenter;
import com.accum.client.presenter.WordListPresenter;
import com.accum.client.view.WordListView;
import com.google.gwt.event.shared.HandlerManager;
import com.google.gwt.user.client.ui.HasWidgets;

public class AppController implements Presenter {
	private final HandlerManager eventBus;
	private final GreetingServiceAsync rpcService;
	private HasWidgets container;
	
	public AppController(GreetingServiceAsync rpcService, HandlerManager eventBus){
		this.eventBus = eventBus;
		this.rpcService = rpcService;
	}

	@Override
	public void bind() {
		// TODO Auto-generated method stub
		
	}

	@Override
	public void go(HasWidgets container) {
		this.container = container;
		
		Presenter presenter = new WordListPresenter(rpcService, eventBus, new WordListView());
		presenter.go(container);
		
	}

}
